-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add end_date_before arg to the script #22
base: main
Are you sure you want to change the base?
Conversation
Add "end_days_before" documents
Hey @gharghi |
Update instruction of using stat_date and end_date
Your comment makes sense. |
@@ -58,7 +58,16 @@ will keep committing. | |||
```sh | |||
python contribute.py --days_before=10 --days_after=15 | |||
``` | |||
Use `--start_date` to specify start date of commits. This option doesn't work if used with days_before. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would propose making them mutually exclusive. If one of them is specified, the script should work. If both are specified, it should show an error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It shouldn't.
Imagine you need to set a period of time in last year.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I mean, if someone uses both --days_before
and --start_date
this should lead to an error
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It could be. But I thought to make it more error free and handle them in the code.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is better when the logic is explicit and the user doesn't have to guess what would happen when they specify two parameters that collide
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I vote --days_before
be removed altogether or just error out on if both are specified and if --days_before
is removed also want to remove --days_after
of course. I think specifying a date is the better route for the tool since it's more intrinsically what a user expects for options. Additionally it allows you to splice up your commit dates uniquely so the graph can be a bit more chaotic whereas --days_before
(and especially --days_after
) I find fairly useless.
And of course it would break backwards compatibility if anyone cares about that 😄
Add feature to specify the finish date before current dats. For example run script from 50 days to 10 days before current date.